package com.bbzn.user.client.dao.role;

import com.bbzn.user.client.dataobject.Permission;
import com.bbzn.user.client.dataobject.RolePermission;
import java.util.List;
import org.apache.ibatis.annotations.Param;

public interface RolePermissionMapper {
    int deleteByPrimaryKey(@Param("roleId") Integer roleId, @Param("permId") Long permId);

    int deleteByRoleId(@Param("roleId") Integer roleId);

    int insert(RolePermission record);

    int insertOrUpdate(RolePermission record);

    int insertOrUpdateSelective(RolePermission record);

    int insertSelective(RolePermission record);

    List<RolePermission> findByAll(RolePermission rolePermission);

    int updateBatch(List<RolePermission> list);

    int updateBatchSelective(List<RolePermission> list);

    int batchInsert(@Param("list") List<RolePermission> list);

    List<RolePermission>  getRolePermissionByPerId(@Param("ids") List<Long> ids );

    List<Long> findPermissionIdByRoleId(@Param("roleId")int roleId);
}